<template>
    <view >
        <view>
            <pageTitle title="创业伯乐研究" url="/pages/index/index"/>
            <view >
                <view class="space-between" v-for="item in baseList" :key="item.id" style="margin-bottom: 20upx;" @click="handClick">
                    <img :src="item.img_url" alt="" class="page_img">
                    <view class="page_con">
                        <h6 class="page_title">{{item.name}}</h6>
                        <view class="page_desc ellipsis">{{item.desc_text}}</view>
                    </view>
                </view>
            </view>
        </view>
    </view>
</template>

<script>
import newsItem from './news-item.vue';
import uniLoadMore from '@/components/uni-load-more.vue';
import noData from '@/components/nodata.vue';
import pageTitle from '@/components/pageTitle.vue';

export default {
    components: {
        uniLoadMore,
        noData,
        newsItem,
        pageTitle
    },
    props: {
        nid: {
            type: [Number, String],
            default: ''
        },
        baseList:[]
    },
    data() {
        return {
            dataList: [],
            navigateFlag: false,
            pulling: false,
            refreshing: false,
            refreshFlag: false,
            refreshText: "",
            isLoading: false,
            loadingText: '加载中...',
            isNoData: false,
            pulling: false,
            angle: 0,
            loadingMoreText: {
                contentdown: '',
                contentrefresh: '',
                contentnomore: ''
            },
            indexList: [],
            urls: [
                {
                    url: 'https://cdn.uviewui.com/uview/album/1.jpg',
                    titel:'人工智能研究',
                    desc : '人工智能大数据资源服务商'
                },
                {
                    url: 'https://cdn.uviewui.com/uview/album/1.jpg',
                    titel:'人工智能研究',
                    desc : '人工智能大数据资源服务商'
                },
                {
                    url: 'https://cdn.uviewui.com/uview/album/1.jpg',
                    titel:'人工智能研究',
                    desc : '人工智能大数据资源服务商'
                }
            ],
        refreshIcon: ""
        }
    },
    created() {
        this.pullTimer = null;
        this.requestParams = {
            columnId: this.nid,
            minId: 0,
            pageSize: 10,
            column: 'id,post_id,title,author_name,cover,published_at,comments_count'
        };

        this._isWidescreen = false;
    },
    methods: {
        handClick() {
            uni.navigateTo({
                url:'/pages/research/details'
            })
        },
    }
}
</script>

<style scoped>
    .yanjiu{
        display: grid;
        grid-template-columns: 120upx 1fr;
    }
    .page_con{
        flex: 1;
        max-width: calc(100% - 120upx);
        padding-left: 20upx;
        box-sizing: border-box;
    }
    .page_img{
        width: 120upx;
        height: 120upx;
        border-radius: 50%;
        background-color: #f0f0f0;
    }
    .page_desc{
        color: #999;
        font-size: 22upx;
        max-width: calc(100% - 120upx);
    }
    .page_title{
        margin-top: 10upx;
        margin-bottom: 20upx;
    }
</style>
